<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@include file="/view/common/header-talent.jsp"%>
<center>
	<h1>修改简历</h1>
</center>
<hr>

<form
	action="<%=request.getContextPath()%>/ResumeServlet?command=update"
	method="post" onsubmit="return validate();">
	<input type="hidden" name="resumeId" value="${resume.id }" />
	<div class="form-group">
		<input type="text" class="form-control" id="intention"
			name="intention" placeholder="求职意向..." autofocus="autofocus"
			value="${resume.intention }"> <span id="intentionInfo"></span>
	</div>
	<div class="form-group">
		<textarea style="overflow: hidden" class="form-control" rows="5"
			id="workExperience" name="workExperience" placeholder="工作经历...">${resume.workExperience }</textarea>
		<span id="workExperienceInfo"></span>
	</div>
	<div class="form-group">
		<textarea style="overflow: hidden" class="form-control" rows="5"
			id="projectExperience" name="projectExperience" placeholder="项目经验...">${resume.projectExperience }</textarea>
		<span id="projectExperienceInfo"></span>
	</div>

	<input type="submit" class="btn btn-primary" value="修改"> <input
		type="button" class="btn btn-default" onclick="goHome()"
		value="返回" />
</form>
<script>
<!--
	/**
	 * 表单验证
	 */
	function validate() {
		var result = true;
		var codeDOM = document.getElementById('code');
		var passwordDOM = document.getElementById('password');
		var rePasswordDOM = document.getElementById('rePassword');
		var nameDOM = document.getElementById('name');
		var phoneDOM = document.getElementById('phone');
		var emailDOM = document.getElementById('email');
		var ageDOM = document.getElementById('age');
		if (codeDOM.value == '') {
			document.getElementById('codeInfo').innerHTML = '<font color="red">账号不能为空!</font>';
			result = false;
		} else {
			document.getElementById('codeInfo').innerHTML = '';
		}
		if (passwordDOM.value == '') {
			document.getElementById('passwordInfo').innerHTML = '<font color="red">密码不能为空!</font>';
			result = false;
		} else {
			document.getElementById('passwordInfo').innerHTML = '';
		}
		if (passwordDOM.value != rePasswordDOM.value) {
			document.getElementById('rePasswordInfo').innerHTML = '<font color="red">密码输入错误!</font>';
			result = false;
		} else {
			document.getElementById('rePasswordInfo').innerHTML = '';
		}
		if (nameDOM.value == '') {
			document.getElementById('nameInfo').innerHTML = '<font color="red">名字不能为空!</font>';
			result = false;
		} else {
			document.getElementById('nameInfo').innerHTML = '';
		}
		if (phoneDOM.value == '') {
			document.getElementById('phoneInfo').innerHTML = '<font color="red">电话不能为空!</font>';
			result = false;
		} else {
			document.getElementById('phoneInfo').innerHTML = '';
		}
		if (emailDOM.value == '') {
			document.getElementById('emailInfo').innerHTML = '<font color="red">邮箱不能为空!</font>';
			result = false;
		} else {
			document.getElementById('emailInfo').innerHTML = '';
		}
		if (ageDOM.value == '') {
			document.getElementById('ageInfo').innerHTML = '<font color="red">年龄不能为空!</font>';
			result = false;
		} else {
			document.getElementById('ageInfo').innerHTML = '';
		}
		return result;
	}
	-->
	
</script>
</body>
</html>